import paddle
import numpy as np

in1 = np.array([[1, 2, 3],
                [4, 5, 6]])
in2 = np.array([[11, 12, 13],
                [14, 15, 16]])
in3 = np.array([[21, 22],
                [23, 24]])
x1 = paddle.to_tensor(in1)
x2 = paddle.to_tensor(in2)
x3 = paddle.to_tensor(in3)
zero = paddle.full(shape=[1], dtype='int32', fill_value=0)
# When the axis is negative, the real axis is (axis + Rank(x))
# As follow, axis is -1, Rank(x) is 2, the real axis is 1
out1 = paddle.concat(x=(x1, x1, x1), axis=-1)
out2 = paddle.concat(x=(x1, x1, x1), axis=0)
out3 = paddle.concat(x=[x1, x2], axis=zero)
print(out1, out2, out3)
